package com.oocl.rcm.util;

import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;

import com.oocl.rcm.model.Customer;

public class FormatPrinter {
	
	public static void printCustomer(Customer[] cs){
		for (int i = 0; i < cs.length; i++) {
			System.out.print(cs[i].getId() + "\t" + cs[i].getName() + '\t' + cs[i].getSex() + '\t' + cs[i].getBirthday() + '\t' + cs[i].getAddress() + '\t' + cs[i].getCall());
			System.out.println();
		}
	}
	
	public void printHelp(){
		System.out.println("--------------------------------------");
		System.out.println("Usage:	[Control]  [args...]:");
		System.out.println("Options:");
		System.out.println("\t" + "L  [arg]" + '\t' + "select all of member's information or someone's;");
		System.out.println("\t" + "A  [args]" + '\t' + "add a member information;");
		System.out.println("\t" + "D  [id]" + '\t' + '\t' + "delete a member information by id;");
		System.out.println("\t" + "U  [args]" + '\t' + "Update information;");
		System.out.println("\t" + "O  [arg]" + '\t' + "order all of imformation and list;");
		System.out.println("\t" + "H" + '\t' + '\t' + "display this help;");
		System.out.println("\t" + "Q" + '\t' + '\t' + "Exit the program;");
		System.out.println("---------------------------------------");
	}
	
	public void printStart(){
		System.out.println("Welcome to ITA CRM:");
		printHelp();
	}
	
	public void cmdError(){
		System.out.println("command error!");
	}
	
	public void printAddSuccess(){
		System.out.println("add success!");
	}
	public void printUpdateSuccess(){
		System.out.println("update success!");
	}
	public void printDeleteSuccess(){
		System.out.println("delete success!");
	}
	public void printNotResult(){
		System.out.println("Do not find result!");
	}
}
